Skip to content

Conversation

@pujagani
Copy link
Contributor

@pujagani pujagani commented Feb 3, 2025

User description

Thanks for contributing to Selenium!
A PR well described will help maintainers to quickly review and merge it

Before submitting your PR, please check our contributing guidelines.
Avoid large PRs, help reviewers by making them as simple and short as possible.

Motivation and Context

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)

Checklist

  • I have read the contributing document.
  • My change requires a change to the documentation.
  • I have updated the documentation accordingly.
  • I have added tests to cover my changes.
  • All new and existing tests passed.

PR Type

Bug fix


Description

  • Reverted the addition of the remote.active-protocols preference in Firefox options.

  • Removed references to enabling CDP protocol by default in Firefox across multiple bindings.

  • Updated tests to reflect the removal of the remote.active-protocols preference.


Changes walkthrough 📝

Relevant files
Bug fix
5 files
FirefoxOptions.java
Removed `remote.active-protocols` preference from Firefox options.
+0/-4     
FirefoxOptions.cs
Removed `remote.active-protocols` preference from Firefox options.
+0/-3     
firefox.js
Removed `remote.active-protocols` preference from Firefox options.
+0/-3     
options.rb
Removed `remote.active-protocols` preference from Firefox options.
+0/-3     
options.py
Removed `remote.active-protocols` preference from Firefox options.
+0/-2     
Tests
5 files
options_test.js
Updated tests to remove remote.active-protocols preference validation.
+1/-7     
driver_spec.rb
Updated tests to remove remote.active-protocols preference validation.
+2/-5     
options_spec.rb
Updated tests to reflect removal of remote.active-protocols
preference.
+4/-4     
firefox_options_tests.py
Updated tests to reflect removal of remote.active-protocols
preference.
+1/-1     
new_session_tests.py
Updated tests to reflect removal of remote.active-protocols
preference.
+2/-2     

Need help?
  • Type /help how to ... in the comments thread for any questions about Qodo Merge usage.
  • Check out the documentation for more information.
  • @qodo-merge-pro
    Copy link
    Contributor

    qodo-merge-pro bot commented Feb 3, 2025

    PR Reviewer Guide 🔍

    Here are some key observations to aid the review process:

    ⏱️ Estimated effort to review: 2 🔵🔵⚪⚪⚪
    🧪 PR contains tests
    🔒 No security concerns identified
    ⚡ Recommended focus areas for review

    Inconsistent Change

    The preference 'remote.active-protocols' is still being set in the Python implementation while it was removed from all other language bindings. This creates inconsistent behavior across different Selenium bindings.

    self._preferences["remote.active-protocols"] = 3

    @qodo-merge-pro
    Copy link
    Contributor

    qodo-merge-pro bot commented Feb 3, 2025

    PR Code Suggestions ✨

    Explore these optional code suggestions:

    CategorySuggestion                                                                                                                                    Score
    Possible issue
    Remove protocol preference setting

    Remove the hardcoded preference setting for 'remote.active-protocols' since this
    PR's purpose is to revert the protocol preference change for Firefox.

    py/selenium/webdriver/firefox/options.py [43-50]

     def __init__(self) -> None:
         super().__init__()
         self._binary_location = ""
         self._preferences: dict = {}
    -    self._preferences["remote.active-protocols"] = 3
         self._profile: Optional[FirefoxProfile] = None
         self.log = Log()
    • Apply this suggestion
    Suggestion importance[1-10]: 10

    Why: The suggestion correctly identifies the need to remove the hardcoded 'remote.active-protocols' preference, which aligns with the PR's purpose of removing this setting across all language bindings. This change is critical for maintaining consistency with Firefox's protocol handling changes.

    10

    @pujagani pujagani marked this pull request as draft February 3, 2025 13:33
    @pujagani pujagani closed this Feb 3, 2025
    Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

    Projects

    None yet

    Development

    Successfully merging this pull request may close these issues.

    1 participant